Repository navigation
BUILD: Name each fetched data file before the Python tests run - #281
Merged
Merged
Conversation
ip-intelligence/ci/fetch-assets.ps1 sets _51DEGREES_IPI_PATH to the Enterprise data file it fetched, with $env:, so the tests that common-ci runs in the same process read it. device-detection/ci/fetch-assets.ps1 sets _51DEGREES_DD_PATH to the Lite data file it fetched. The IP Intelligence fetch script also fetches the device detection Lite file, which the mixed examples use, and names it in _51DEGREES_DD_PATH, so it is there when only IP Intelligence is tested. The free-threaded test step sets both variables to the Lite files it restores from its cache. The key names and free-threaded Pester tests check each of these. What a person running the examples gets is unchanged.
ip-intelligence/ci/fetch-assets.ps1 named the Enterprise data file in _51DEGREES_IPI_PATH, and the tests and examples accept the free Lite file, which the script already fetches. It now names the Lite file, and a new test in ci/key-names.Tests.ps1 checks that it does. The test that the script still asks common-ci for the Enterprise file stays, although nothing reads that file now, and an example test comment that said CI names the Enterprise file is corrected.
Merged
rc moved the free-threaded workflow's data files from its own cache to the assets common-ci fetches, and took out the test of the cached paths and its Get-Paths helper. The test that each test job sets _51DEGREES_DD_PATH and _51DEGREES_IPI_PATH before pytest runs now checks that the variables are set after the step that puts the files in place, rather than reading the cache paths.
Collaborator
|
Merged into rc for the 4.6.2 release. The only failing check is the cloud available properties test, which fails because the CI resource key does not yet include the new ServiceWorkers property. Pull Requests run 46470818602 tested this head, 878792d, and every other test there passed. This pull request and #290 both change ci/key-names.Tests.ps1, so the CI script tests were also run on rc with this merged in: the same tests pass as on rc alone, plus this pull request's own. |
Rakesh51D
added a commit
that referenced
this pull request
Nov 30, 2026
Brings in #290, which runs the 51Did and Human Confidence cloud tests against the staging cloud, and #281, #282 and #288. Two test files conflicted, and both keep the tests rc runs on staging. - pipeline/fiftyone_pipeline_did/tests/test_did_client_live.py: the browser creator context test names the 51Did Properties on the page's Resource Key call, as this branch does. Where that first answer carries no 51Did because the call requested HumanConfidence and was handed the browser tests, it asks with the licence key alone, as rc does. Any other answer without a 51Did still fails. The client test's own call is rc's, which gets its 51Did on staging. - pipeline/fiftyone_pipeline_cloudrequestengine/examples/tests/ test_cloud_humanconfidence_web.py: rc's tests, with is_sealed using the package's is_blank, so a blank value is never a sealed result. Run locally on Python 3.12 with no keys: fiftyone_pipeline_did 343 passed and 8 skipped, the cloud request engine examples 99 passed and 32 skipped. The live and staging tests skip without keys, so the Cloud 51Did and Cloud Human Confidence checks prove them.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The IP Intelligence on-premise tests read the data file named in
_51DEGREES_IPI_PATH, and the device detection web getting started example reads_51DEGREES_DD_PATH. In CI the IP Intelligence fetch script wrote its variable where the tests in the same step could not see it, and nothing named the device detection file. Each fetch script now names the file it has just fetched, in the process the tests run in.What changes
ip-intelligence/ci/fetch-assets.ps1sets_51DEGREES_IPI_PATHwith$env:to the Lite data file it fetched,51Degrees-LiteIpiV41.ipi. common-ci runs this script and the tests in one step, so the IP Intelligence on-premise tests read it. The IP Intelligence examples take the variable only when it names the file they ask for,51Degrees-LiteV41.ipi, so they still find the Lite file through the link the script makes under that name incxx/data/ip-intelligence.device-detection/ci/fetch-assets.ps1sets_51DEGREES_DD_PATHto the Lite data file it fetched, which the web getting started example reads. The examples that look for their file withfind_filedo not read the variable, and find the file through the link the script makes incxx/data/device-detection.ip-intelligence/ci/fetch-assets.ps1also fetches the device detection Lite data file and links it intoip-intelligence/assets, where the mixed examples find it. It sets_51DEGREES_DD_PATHtoo, which no IP Intelligence example or test reads..github/workflows/free-threaded-python.ymlsets both variables to the Lite files it restores from its cache.ci/key-names.Tests.ps1andci/free-threaded-python.Tests.ps1check each of these.What a person running the examples gets is unchanged.
Tests
ci/key-names.Tests.ps1andci/free-threaded-python.Tests.ps1with Pester 5.7.1 on Windows all pass, and each new or changed test fails against the scripts as they were.ci/*.Tests.ps1on Windows: 453 passed, 0 failed, at the second commit, which names the Lite file. Its new test, that the script names the Lite file it fetched, failed at the first commit.Before this leaves draft
Not ready to merge until these are done.
ip-intelligence/ci/fetch-assets.ps1still fetches the Enterprise file (about 2.3 GB), as no test reads it now, or one test names it.